
<%@ include file="/common/taglibs.jsp"%>
<!--分页查询共用的页面-->
<%@ include file="/common/common.jsp"%>
<%@ page language="java" pageEncoding="UTF-8"%>
	<!--下拉树的配置-->
	

<script>
	function newBasicData()
	{
	    $("#entityId").val(0);
        $("#name").val("");
        $("#code").val("");
	}
$().ready(function() {
    $("#entityForm").validate(); //初始化验证信息
 
	 $("#parent").lookup({category:"Root", selectedValue:"${entity.parent}"});

	 var sn = "${entity.sn}";

	 if(sn.length == 0)
		 $("#sn").val(0);
 
});
</script>
 <BODY>


	<form id="entityForm" name="entityForm" 
			action='<%=ApplicationPath%>/basicData/save.action' method="POST">
				<input type="hidden" id="entityId" name="entityId"
					value="${entity.entityId}"/>
  <table width="100%"  class="TableBlock">
					<tbody><tr>
						<td colspan="4" style="font-weight: bold; background: #EFEFEF;" height="25">基础信息
						<span class="MessageFromServer">${message}</span>
						</td>
					</tr>
					<tr>
						<td align="right" width="40%">类型:</td>
						<td align="left"><select  id="parent" value="${entity.parent}"
						name="parent"  > 
						</select>
						</td>
					</tr>
					<tr>
						<td align="right">名称:</td>
						<td align="left"><input  id="name" value="${entity.name}"
						name="name" class="required"  size="20"> 
						</td>
					</tr>
						<td align="right">编码:</td>
						<td align="left"><input id="code" name="code" value="${entity.code}" size="20" class="required" >
						</td>
					</tr>
					</tr>
						<td align="right">排序:</td>
						<td align="left"><input id="sn" name="sn" value="${entity.sn}" size="20" class="required digits" >（数字)
						</td>
					</tr>
	
					<tr>
						<td colspan=4 align=center>

							<button type="submit" class="button green medium" ><i class="fa fa-check" style="margin-right:3px;"></i> 保存</button>

							<button type="button" class="button blue medium" onclick="newBasicData();" ><i class="fa fa-copy" style="margin-right:3px;"></i> 新增</button>
						</td>
					</tr>
				</tbody></table>
 </BODY>
</HTML>
